<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Novel extends Model
{
    protected $table='novel';
    const CREATED_AT = 'create_time';
    const UPDATED_AT = 'update_time';
    protected $guarded = [];
    public function category(){
        
            return $this->belongsTo('App\Category', 'novel_cid', 'id');
       
    }
    public function type(){
        
        return $this->belongsTo('App\Type', 'typeid', 'id');
   
}
}
